#define _CRT_SECURE_NO_WARNINGS 1
#include <stdio.h>

char* my_strncat(char* dest, const char* src, size_t count)
{
	char* ret = dest;
	while (*dest)
	{
		dest++;
	}
	int i = 0;
	for (i = 0; *src&&i < count; i++)
	{
		*dest++ = *src++;
	}
	if (i < count)
	{
		*dest = *src;
	}
}
int main()
{
	char arr1[10] = "hello ";
	char arr2[] = "bit";
	my_strncat(arr1, arr2, 8);
	printf("%s\n", arr1);
	return 0;
}